<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<html>
<link rel="stylesheet" type="text/css" href="<%= request.getContextPath() %>/css/style_int.css">
<script src="<%= request.getContextPath() %>/jscripts/jscripts.js" type="text/javascript"></script>
<body onload="reSize()">
	<table width="100%" border="0" cellpadding="0" cellspacing="1" background="url(../images/fond_page.png)" style="border: 1px solid #73802E;font-size:12px;font-family:Verdana;">
		<tr>
			<td align="center" class="td_head">&nbsp;</td>
			<td height="25" align="center" class="td_head">C&oacute;digo</td>
			<td align="center" class="td_head">Estado</td>
			<td align="center" class="td_head">Fecha</td>
			<td align="center" class="td_head">Direcci&oacute;n de Entrega</td>
		</tr>
		<c:set var="cantidad" value="0"></c:set>
		<c:forEach var="pedido" items="${listaPedidos}">
			<tr>
				<td height="25" align="center">
				    <input type="radio" name="pedidoSeleccionado" onclick="JavaScript:cargarListadoProductos('${pedido.idPedido}');">
				</td>
				<td align="center">${pedido.idPedido}</td>
				<td align="center">${pedido.estado}</td>
				<td align="center">${pedido.fechaRegistro}</td>
				<td align="center">${pedido.direccionEntrega}</td>
			</tr>
		</c:forEach>
	</table>
	<br>
</body>
<script type="text/javascript">
function reSize(){
	if('${cantidad}' != '0'){
		try{
			  var iframe = parent.document.getElementById("frm_listadoProducto");
			  var innerDoc = (iframe.contentDocument) ? iframe.contentDocument : iframe.contentWindow.document;
		      if (innerDoc.body.offsetHeight){//ns6 syntax
		         iframe.height = 26*${cantidad} + 80; //Extra height FireFox
		      }
		      else if (iframe.Document && iframe.Document.body.scrollHeight){//ie5+ syntax
		         iframe.height = iframe.Document.body.scrollHeight;
		      }
		    }catch(err){
		      alert(err.message);
		    }
	}
}
</script>
</html>
